package org.langqiao.io.file;

import java.io.BufferedReader;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStreamReader;

public class TrainInfo {
	public static void main(String[] args){
		File file=new File("F:/train.txt");
		try {
			BufferedReader br = new BufferedReader(new InputStreamReader(new FileInputStream(file)));
			String line = null;
			StringBuffer sb = new StringBuffer();
			while((line = br.readLine())!=null){
				System.out.println(line);
				String[] arr = line.split("\t");
				//for(int i=0;i<arr.length;i++){
					sb.append(arr[0]).append(":").append(arr[1]).append(",").append(arr[3]).append("->").append(arr[4]).append(",").append(5).append(",").append(6);
				//}
				//line = br.readLine();
				
			}
			System.out.println(sb.toString());
		} catch (FileNotFoundException e) {
			e.printStackTrace();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}

}
